package com.newegg.nlp.arangodb.model;

import java.util.Collection;
import com.arangodb.springframework.annotation.Document;
import com.arangodb.springframework.annotation.HashIndex;
import com.arangodb.springframework.annotation.Relations;
import com.newegg.nlp.arangodb.BaseModel;

@Document("item")
@HashIndex(fields = { "itemnumber" }, unique = true)
public class Item extends BaseModel{
	
	//商品ID
	String itemnumber;
	
	//商品名称
	String name;
	
	@Relations(edges=CategoryItem.class)
	Category category;
	
	@Relations(edges=BrandItem.class)
	Brand brand;
	
	@Relations(edges=ItemAdjective.class, lazy=true)
	Collection<Adjective> adjectives;
	
	@Relations(edges=ItemNoun.class, lazy=true)
	Collection<Noun> nouns;
	
	@Relations(edges=ItemKeyword.class, lazy=true)
	Collection<Keyword> keywords;
	

	public String getItemnumber() {
		return itemnumber;
	}

	public void setItemnumber(String itemnumber) {
		this.itemnumber = itemnumber;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Category getCategory() {
		return category;
	}

	public void setCategory(Category category) {
		this.category = category;
	}

	public Brand getBrand() {
		return brand;
	}

	public void setBrand(Brand brand) {
		this.brand = brand;
	}

	public Collection<Adjective> getAdjectives() {
		return adjectives;
	}

	public void setAdjectives(Collection<Adjective> adjectives) {
		this.adjectives = adjectives;
	}

	public Collection<Noun> getNouns() {
		return nouns;
	}

	public void setNouns(Collection<Noun> nouns) {
		this.nouns = nouns;
	}

	public Collection<Keyword> getKeywords() {
		return keywords;
	}

	public void setKeywords(Collection<Keyword> keywords) {
		this.keywords = keywords;
	}
}
